<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
    <head>
        <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
        <title></title>
        <script src="../glassboxLatest/glassbox.2.0.0/javascripts/prototype.js" type="text/javascript"></script>
        <script src="../glassboxLatest/glassbox.2.0.0/javascripts/scriptaculous/effects.js" type="text/javascript"></script>
        <script src="../glassboxLatest/glassbox.2.0.0/javascripts/glassbox/glassbox.js" type="text/javascript"></script>
        <style>
            body {
                font-size: 10px;
                background: url(../images/sfondoContainer.jpg );
                background-color :  #5767ab;
                background-attachment: fixed;
                font-family: verdana, arial, helvetica;
                font-size: 12px;
                text-align: center;
            }
            #wrapper {
                margin: 0 auto;
                text-align:left;
                width: 952px;
            }

            #userBox {
                padding-top: 5%;
            }

            #userBoxCont
            {
                padding-top: 3%;
                padding-left: 15%;
            }
            #myBox_contentBoxBg {
                background: url(../images/sfondoContainer.jpg );
                background-color :  #5767ab;
                filter: alpha(opacity=50);
                -moz-opacity:.50;
                opacity:.50;
            }
            #myBox{
                display: none;
            }
            #myBox_content {
                background: url(../images/sfondoContainer.jpg );
                background-color :  #5767ab;
                padding: 20px;
            }
            #myBox h3 {
                font-size: 17px;
                margin: 0px;
                text-align: center
            }


        </style>
        <script type="text/javascript">
            path_to_root_dir = "../glassboxLatest/glassbox.2.0.0/";
            window.onload = function(){

                var disciplinaBox = new GlassBox();
                disciplinaBox.init( 'userBox', '620px', '310px', 'hidden','',false);
                disciplinaBox.ipos();
                disciplinaBox.appear();
            }

            function xXMLHttpRequest()
            {

                var client = null;
                if (window.XMLHttpRequest)
                {
                    client=new XMLHttpRequest();
                }
                // code for IE
                else if (window.ActiveXObject)
                {
                    client=new ActiveXObject("Microsoft.XMLHTTP");
                }

                return client;
            }

            function handler() {
                if(this.readyState == 4 && this.status == 200) {
                    var myBox = new GlassBox();
                    myBox.init( 'myBox', '400px', '100px', 'hidden', '', false, true );
                    myBox.lbo(false, 0.5);

                    myBox.appear(3000);

                } else if (this.readyState == 4 && this.status != 200) {
                    // fetched the wrong page or network error...
                    alert("error this.status : " + this.responseText);

                }
            }

            function submitForm()
            {
                var client = xXMLHttpRequest();
                client.onreadystatechange = handler;
                
                var param = 
                    "nome="+document.getElementById('nome').value +
                    "&descrizione="+document.getElementById('descrizione').value;
                client.open("POST", "nuovaDisciplina.php", false);
                client.setRequestHeader('Content-Type', 'application/x-www-form-urlencoded');

                client.send(param);

            }
        </script>
    </head>
    <body>
        <form onsubmit="submitForm();">
            <label>Nome : </label>
            <input type="text" name="nome" id="nome"/><br>
            <label>Descrizione : </label>
            <input type="text" name="descrizione" id="descrizione"/><br>
            <input type="submit" value="Inserisci" />

        </form>
        <a href="../portal/menu.php">Menù</a>
    </body>
</html>
